package com.example.conf.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.gitee.sunchenbin.mybatis.actable.annotation.Column;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 用户积分余额信息变动记录表
 * </p>
 *
 * @author wpdcn
 * @since 2020-05-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("shop_member_change_record")
@ApiModel(value="ShopMemberChangeRecordEntity对象", description="用户积分余额信息变动记录表")
public class ShopMemberChangeRecordEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @Column(comment = "主键id")
    @ApiModelProperty(value = "主键id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Column(comment = "类型：1-后台操作；2-商城下单；3-物业单；4-购买会员卡")
    @ApiModelProperty("类型：1-后台操作；2-商城下单；3-物业单；4-购买会员卡")
    private String type;

    @Column(comment = "会员id")
    @ApiModelProperty(value = "会员id")
    private String memberId;

    @Column(comment = "会员手机号")
    @ApiModelProperty("会员手机号")
    @TableField(exist = false)
    private String mobile;

    @Column(comment = "会员昵称")
    @ApiModelProperty("会员昵称")
    @TableField(exist = false)
    private String nickName;

    @Column(comment = "变更前账户积分")
    @ApiModelProperty(value = "变更前账户积分")
    private Double oldScore;

    @Column(comment = "变更后账户积分")
    @ApiModelProperty(value = "变更后账户积分")
    private Double newScore;

    @Column(comment = "变更前账户余额")
    @ApiModelProperty(value = "变更前账户余额")
    private Double oldBalance;

    @Column(comment = "变更后账户余额")
    @ApiModelProperty(value = "变更后账户余额")
    private Double newBalance;

    @Column(comment = "备注")
    @ApiModelProperty("备注")
    private String remark;

    @Column(comment = "操作人")
    @ApiModelProperty(value = "操作人")
    private Long createBy;

    @Column(comment = "操作人名称")
    @ApiModelProperty("操作人名称")
    @TableField(exist = false)
    private String createName;

    @Column(comment = "创建时间")
    private LocalDateTime createTime;

    @Column(comment = "相关订单号")
    @ApiModelProperty("相关订单号")
    private String orderNo;


}
